import Vue from 'vue'
import Router from 'vue-router'

import portal from '../modules/protal/portal.vue';
import map from '../modules/map/map.vue';

Vue.use(Router);

const routes = [
    {
        path: '/',
        redirect: '/portal', //必须有配置这个路径，否则转发无效
        component: portal,
        meta: { requiresAuth: true },
    },
    {
        path: '/portal',
        name: 'portal',
        component: portal,
        meta: { requiresAuth: true },
    },
    {
        path: '/mapone',
        name: 'mapone',
        component: map,
        meta: { requiresAuth: true },
    }
]
 
const router = new Router({
    mode: 'history',
    // base: 'D-Square',
    routes
});
 
export default router;